package dinarytree;

/**
 * @Author liangzai
 * @Description:
 */
public class Test {
    public static void main(String[] args) {
        BinaryTree tree = new BinaryTree();
        //String str = "abc##de#g##f###";
        //TreeNode root = tree.createTree(str);
        TreeNode root = tree.creatTree();
        //tree.isCompleteTree(root);
        System.out.println(tree.isCompleteTree(root));
        tree.levelOrder(root);

        tree.preOrderNor(root);
        tree.preOrder(root);
        System.out.println();
        System.out.println("========前序========");

        tree.inOrderNor(root);
        tree.inOrder(root);
        System.out.println();
        System.out.println("========中序========");

        tree.outOrderNor(root);
        tree.outOrder(root);
        System.out.println();
        System.out.println("========后序========");

        System.out.println(tree.size(root));
        System.out.println(tree.getLeafNode2(root));
        System.out.println(tree.getKlevelNode(root,4));
        System.out.println(tree.getMaxDepth(root));
        //System.out.println(tree.find(root,'H').val);
    }
}
